package dao;

import javax.persistence.EntityManager;

import org.springframework.stereotype.Service;

import entities.Vinho;


@Service("vinhoDAO")
public class ImpleVinhoDAO implements VinhoDAO{

	private EntityManager entityManager;
	
	public ImpleVinhoDAO(EntityManager entityManager) {
		
		this.entityManager= entityManager;
		
	}

	public void incluirVinho(Vinho vinho) {
		System.out.println("Incluindo Vinho");
		
		this.entityManager.persist(vinho);
		
	}

}
